#ifndef PROGRAMLIST_H
#define PROGRAMLIST_H

#include "program.h"
#include <vector>

namespace tv {


class ProgramList : public std::vector< Program >
{
public:
    ProgramList();

    bool load(const char* filepath);

    bool save(const char* filepath);

    size_t indexOf(const std::string& num);

    size_t indexWithName(const std::string& name);

    bool contains(const std::string& num);

    std::string getFilePath();

    bool remove(size_t idx, Program& program);
    bool remove(size_t idx);

protected:
    std::string m_filepath;

};


}

#endif // PROGRAMLIST_H
